<!--
 * @Descripttion: 
 * @Author: voanit
 * @Date: 2022-09-01 09:18:38
 * @LastEditors: voanit
 * @LastEditTime: 2022-09-01 15:18:02
-->
<script setup>
import { storeToRefs } from 'pinia'
import useCounterStore from './store/modules/counter'
// console.log(useCounterStore(), 6);
const counter = useCounterStore()
const { count, total } = storeToRefs(counter)

const btn = () => {
  counter.double()
}

</script>
<template>
  <div>
    御剑乘风来,除魔天地间!===vue3==={{ counter.count }}==={{ count }}
    <button @click="btn">按钮==={{ counter.total }}==={{ total }}</button>
  </div>
</template>
<style lang='less'  scoped>
</style>